/*
 * MessageAdapter.java
 * business
 *
 * Created by ChenTao on 2017/1/9.
 *
 * Copyright (c) 2017年 yidiandao. All rights reserved.
 */

package com.yidiandao.business.ui.adapter;

import android.content.Context;

import com.yidiandao.business.ui.widget.listview.CommonAdapter;
import com.yidiandao.business.ui.widget.listview.DisplayItemManager;
import com.yidiandao.business.ui.widget.listview.DisplayListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.DiscoveryActivityMessageListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.AssetMessageListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.FavourableMessageListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.LogisticsMessageListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.ServiceMessageListItem;
import com.yidiandao.business.ui.widget.listview.displaylistitem.SystemMessageListItem;

/**
 * 个人中心-消息-Adapter
 */
public class MessageAdapter extends CommonAdapter<DisplayListItem> {

    public MessageAdapter(Context context) {
        super(context);
    }

    @Override
    protected void registerDisplayListItemMap() {
        DisplayItemManager.register(getAdapterTag(), SystemMessageListItem.class);
        DisplayItemManager.register(getAdapterTag(), AssetMessageListItem.class);
        DisplayItemManager.register(getAdapterTag(), FavourableMessageListItem.class);
        DisplayItemManager.register(getAdapterTag(), LogisticsMessageListItem.class);
        DisplayItemManager.register(getAdapterTag(), ServiceMessageListItem.class);
        DisplayItemManager.register(getAdapterTag(), DiscoveryActivityMessageListItem.class);
    }

    @Override
    protected String getAdapterTag() {
        return MessageAdapter.class.getSimpleName();
    }
}
